package sevensoft.创建型模式.工厂模式.静态工厂.store;

import sevensoft.创建型模式.工厂模式.静态工厂.factory.SimpleGunFactory;
import sevensoft.创建型模式.工厂模式.静态工厂.guns.Gun;

public class GunStore {
    public <T extends Gun> Gun orderGun(Class<T> gunClass){
        Gun gun = SimpleGunFactory.createGun(gunClass);
        gun.load();
        gun.shoot();
        return gun;
    }
}
